package com.qq.clone.user.Db.DO;

import java.io.Serial;
import java.io.Serializable;
import java.time.OffsetDateTime;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

/**
 * user
 */
@Data
@TableName("\"user\"") // 指定数据库表名
public class UserDO implements Serializable {
    @TableId(type = IdType.AUTO) // 指定主键及主键生成策略
    @TableField("user_id")
    private Long userId;
    
    @TableField("username")
    private String username;

    @TableField("password")
    private String password;

    @TableField("email")
    private String email;

    @TableField(value = "created_at", fill = FieldFill.INSERT)
    private OffsetDateTime createdAt;

    @TableField("last_login")
    private OffsetDateTime lastLogin;

    @TableField("online")
    private Boolean online;

    @Serial
    private static final long serialVersionUID = 1L;
}